<%@ page contentType="text/html; charset=UTF-8"%>
<%@include file="/html/portlet/chart/datasourcecfg/init.jsp"%>

<portlet:defineObjects />

<liferay-ui:success key="db_test_success" message="chart.dsconfig.test.success"/>
<liferay-ui:error key="db_test_fail" message="chart.dsconfig.test.fail" />
<liferay-ui:search-container  emptyResultsMessage="empty-results-message">
	<liferay-ui:search-container-results 
		results="<%=DataSourceCfgLocalServiceUtil.getDataSourceCfgs(searchContainer.getStart(), searchContainer.getEnd())%>"
		total="<%= DataSourceCfgLocalServiceUtil.getDataSourceCfgsCount() %>" />
		
	<liferay-util:include page="/html/portlet/chart/datasourcecfg/toolbar.jsp" servletContext="<%= application %>" />
	
	<liferay-ui:search-container-row
		className="cn.shuto.liferay.plugin.chart.service.model.DataSourceCfg"
		keyProperty="dataSourceId" modelVar="dscfg" escapedModel="<%=true%>">
		<portlet:renderURL var="rowURL">
			<portlet:param name="dataSourceId"
				value="<%=String.valueOf(dscfg.getDataSourceId()) %>" />
			<portlet:param name="mvcPath"
				value="/html/portlet/chart/datasourcecfg/edit_dscfg.jsp" />
			<portlet:param name="redirect" value="<%= currentURL %>" />
		</portlet:renderURL>
		<liferay-ui:search-container-column-text name="chart.dsconfig.id"
					property="dataSourceId" href="<%= rowURL %>"/>
		<liferay-ui:search-container-column-text name="name"
			property="name" href="<%= rowURL %>"/>
		<liferay-ui:search-container-column-text name="description"
			property="description" href="<%= rowURL %>"/>
		<liferay-ui:search-container-column-date name="modified-date" property="modifiedDate" href="<%= rowURL %>"/>
		<liferay-ui:search-container-column-text name="author" property="userName" href="<%= rowURL %>"/>
		<liferay-ui:search-container-column-date name="create-date" property="createDate" href="<%= rowURL %>"/>
		
	<liferay-ui:search-container-column-jsp
	            path="/html/portlet/chart/datasourcecfg/dscfg_actions.jsp"
	            align="right" />
	</liferay-ui:search-container-row>

	
	<liferay-ui:search-iterator />
</liferay-ui:search-container>
